package think.in.spring.web.service;

import org.springframework.stereotype.Service;
import think.in.spring.web.annotation.ExecutionTime;

import java.util.concurrent.TimeUnit;

@Service
public class SampleService {

    @ExecutionTime(unit = TimeUnit.MILLISECONDS)
    public void processData() {
        // 模拟耗时操作
        try {
            Thread.sleep(1500);
        } catch (InterruptedException e) {
            Thread.currentThread().interrupt();
        }
    }
}
